﻿using System;
using System.Globalization;
using System.Windows.Data;
using FFmpegVideoClip.Configuration;

namespace FFmpegVideoClip.Lib.UtilityControlsTools
{
    [ValueConversion(typeof(Preset), typeof(bool))]
    internal class IsPresetGroupTitle : IValueConverter
    {
        public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
        {
            if (value == null || value is not Preset preset)
                return false;
            return !preset.IsSplittedTitle;
        }

        public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
        {
            throw new NotImplementedException();
        }
    }
}
